<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>ycrcb2rgb: ycrcb2rgb_example.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="HTML_custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="xlogo_bg.gif"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">ycrcb2rgb
   </div>
   <div id="projectbrief">Xilinx SDK Drivers API Documentation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',false,false,'search.php','Search');
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('ycrcb2rgb__example_8c.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a>  </div>
  <div class="headertitle">
<div class="title">ycrcb2rgb_example.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Overview</h2>
<div class="textblock"><p>This file demonstrates how to use Xilinx YCrCb to RGB Color Space Converter (YCrCb2RGB) driver on Xilinx YCrCb to RGB Color Space Converter (YCrCb2RGB) core. </p>
<pre>
MODIFICATION HISTORY:</pre><pre>Ver   Who  Date     Changes
<hr/>

7.00 adk   07/14/14 First release.
</pre> </div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:a25ff33ab97a74bcfe8a1d4e0fc515ddd"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="ycrcb2rgb__example_8c.html#a25ff33ab97a74bcfe8a1d4e0fc515ddd">XYCC_DEVICE_ID</a>&#160;&#160;&#160;XPAR_YCRCB2RGB_0_DEVICE_ID</td></tr>
<tr class="memdesc:a25ff33ab97a74bcfe8a1d4e0fc515ddd"><td class="mdescLeft">&#160;</td><td class="mdescRight">The following constants map to the XPAR parameters created in the xparameters.h file.  <a href="#a25ff33ab97a74bcfe8a1d4e0fc515ddd">More...</a><br /></td></tr>
<tr class="separator:a25ff33ab97a74bcfe8a1d4e0fc515ddd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:afc3ec4c319b525e8555664ccda21deca"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="ycrcb2rgb__example_8c.html#afc3ec4c319b525e8555664ccda21deca">YCrCb2Rgb_Update_Example</a> (u16 DeviceId)</td></tr>
<tr class="memdesc:afc3ec4c319b525e8555664ccda21deca"><td class="mdescLeft">&#160;</td><td class="mdescRight">YCrCb to RGB Color Space Converter Register Update Example.  <a href="#afc3ec4c319b525e8555664ccda21deca">More...</a><br /></td></tr>
<tr class="separator:afc3ec4c319b525e8555664ccda21deca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a840291bc02cba5474a4cb46a9b9566fe"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="ycrcb2rgb__example_8c.html#a840291bc02cba5474a4cb46a9b9566fe">main</a> (void)</td></tr>
<tr class="memdesc:a840291bc02cba5474a4cb46a9b9566fe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Main function to call the YCrCb2RGB example.  <a href="#a840291bc02cba5474a4cb46a9b9566fe">More...</a><br /></td></tr>
<tr class="separator:a840291bc02cba5474a4cb46a9b9566fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
Variables</h2></td></tr>
<tr class="memitem:ae683a452702e159c435820e18bd219da"><td class="memItemLeft" align="right" valign="top"><a class="el" href="struct_x_y_cr_cb2_rgb.html">XYCrCb2Rgb</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="ycrcb2rgb__example_8c.html#ae683a452702e159c435820e18bd219da">XYccInstance</a></td></tr>
<tr class="memdesc:ae683a452702e159c435820e18bd219da"><td class="mdescLeft">&#160;</td><td class="mdescRight">Instance of the YCRCB2RGB core.  <a href="#ae683a452702e159c435820e18bd219da">More...</a><br /></td></tr>
<tr class="separator:ae683a452702e159c435820e18bd219da"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a id="a25ff33ab97a74bcfe8a1d4e0fc515ddd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a25ff33ab97a74bcfe8a1d4e0fc515ddd">&#9670;&nbsp;</a></span>XYCC_DEVICE_ID</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XYCC_DEVICE_ID&#160;&#160;&#160;XPAR_YCRCB2RGB_0_DEVICE_ID</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The following constants map to the XPAR parameters created in the xparameters.h file. </p>
<p>They are defined here such that a user can easily change all the needed parameters in one place. </p>

<p class="reference">Referenced by <a class="el" href="ycrcb2rgb__example_8c.html#a840291bc02cba5474a4cb46a9b9566fe">main()</a>.</p>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="a840291bc02cba5474a4cb46a9b9566fe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a840291bc02cba5474a4cb46a9b9566fe">&#9670;&nbsp;</a></span>main()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int main </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Main function to call the YCrCb2RGB example. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">None.</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>XST_SUCCESS if successful,</li>
<li>XST_FAILURE if it is unsuccessful</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p class="reference">References <a class="el" href="ycrcb2rgb__example_8c.html#a25ff33ab97a74bcfe8a1d4e0fc515ddd">XYCC_DEVICE_ID</a>, and <a class="el" href="ycrcb2rgb__example_8c.html#afc3ec4c319b525e8555664ccda21deca">YCrCb2Rgb_Update_Example()</a>.</p>

</div>
</div>
<a id="afc3ec4c319b525e8555664ccda21deca"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afc3ec4c319b525e8555664ccda21deca">&#9670;&nbsp;</a></span>YCrCb2Rgb_Update_Example()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int YCrCb2Rgb_Update_Example </td>
          <td>(</td>
          <td class="paramtype">u16&#160;</td>
          <td class="paramname"><em>DeviceId</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>YCrCb to RGB Color Space Converter Register Update Example. </p>
<p>This function provides an example of the process used to update the coefficient and offset registers in the YCRCB2RGB core.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">DeviceId</td><td>is the unique device id of the YCRCB2RGB core.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>XST_SUCCESS if successful,</li>
<li>XST_FAILURE if it is un-successful</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p class="reference">References <a class="el" href="struct_x_y_cr_cb2_rgb___coef___inputs.html#a7c523ee9eadbd22fe493a605f5a1d40c">XYCrCb2Rgb_Coef_Inputs::ACoef</a>, <a class="el" href="struct_x_y_cr_cb2_rgb___coefficients.html#ac9e4ad073b01179ee124fbc01f3410de">XYCrCb2Rgb_Coefficients::ACoef</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga214fd3c975c68cb2ca7988817371c8c7">XYCC_DATA_WIDTH_8</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ggabd7ea7f87d1779cac60386bf999af721a1217ea6e63d324a65afedd246c3afa38">XYCC_STANDARD_ITU_601_SD</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ggadcae94ec346c6a5744c334402ff0968aa3c73c9762977b65219b2ad82a0b4bb73">XYCC_TV_16_TO_240</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gac5025d0ba54b65adaa027af5fb417af6">XYCrCb2Rgb_CfgInitialize()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gabe717fccdb512b0150bc0bf5f3610d59">XYCrCb2Rgb_Coefficient_Translation()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga18ed531addc912f737ee9e8affdc27f2">XYCrCb2Rgb_Enable</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gaf219e40b4fdec9d5653ecedabf57ebeb">XYCrCb2Rgb_LookupConfig()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gaf49957f05febddddb01dfa8cb59177a9">XYCrCb2Rgb_RegUpdateDisable</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga2a3da55454c72455f3f0c2f1d1648826">XYCrCb2Rgb_RegUpdateEnable</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gaf5e8a42e14dd074ae90b9911a5f078fd">XYCrCb2Rgb_Select_OutputRange()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga0072eba5715f04664184a2bbfe9a4247">XYCrCb2Rgb_Select_Standard()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga6de5bc93480ed88dc7322f17c1523fcf">XYCrCb2Rgb_SetActiveSize()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga618a3bf6165c98f133ff6983a7465ec1">XYCrCb2Rgb_SetBOffset()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga140580f95dd9db5de722f7633c9e0502">XYCrCb2Rgb_SetCoefs()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gaab24bb1f0659817b398c656c75606654">XYCrCb2Rgb_SetGOffset()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#gabf1d9aaf3dc5088ad82a067714f02fc6">XYCrCb2Rgb_SetRGBMax()</a>, <a class="el" href="group__ycrcb2rgb__v7__0.html#ga2bbfcd9f4f666b03a7c854d649e8567b">XYCrCb2Rgb_SetRGBMin()</a>, and <a class="el" href="group__ycrcb2rgb__v7__0.html#ga35d2da4c7849193ab8fc0a6a04dd489c">XYCrCb2Rgb_SetROffset()</a>.</p>

<p class="reference">Referenced by <a class="el" href="ycrcb2rgb__example_8c.html#a840291bc02cba5474a4cb46a9b9566fe">main()</a>.</p>

</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a id="ae683a452702e159c435820e18bd219da"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae683a452702e159c435820e18bd219da">&#9670;&nbsp;</a></span>XYccInstance</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="struct_x_y_cr_cb2_rgb.html">XYCrCb2Rgb</a> XYccInstance</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Instance of the YCRCB2RGB core. </p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Copyright &copy; 2015 Xilinx Inc. All rights reserved.</li>
  </ul>
</div>
</body>
</html>
